package com.hawk.eye.server.auth;


/**
 *
 */
public class ServiceAuthHolder {

    private static final ThreadLocal<ServiceAuthMetadata> CONTEXT_HOLDER = new ThreadLocal<>();

    public static ServiceAuthMetadata getServiceAuthMetadata() {
        return CONTEXT_HOLDER.get();
    }

    public static void setServiceAuthMetadata(ServiceAuthMetadata context) {
        CONTEXT_HOLDER.set(context);
    }

    public static void clearServiceAuthMetadata() {
        CONTEXT_HOLDER.remove();
    }

}
